package com.itmk.web.reports.service.impl;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.itmk.web.reports.entity.ReportListParm;
import com.itmk.web.reports.entity.ReportVo;
import com.itmk.web.reports.entity.Reports;
import com.itmk.web.reports.mapper.ReportMapper;
import com.itmk.web.reports.service.ReportService;
import org.springframework.stereotype.Service;

@Service
public class ReportServiceImpl extends ServiceImpl<ReportMapper, Reports> implements ReportService {
    @Override
    public IPage<ReportVo> getReportList(ReportListParm parm) {
        IPage<ReportVo> page = new Page<>(parm.getCurrentPage(), parm.getPageSize());
        // 将分页对象和查询条件传递给 Mapper
        return this.baseMapper.getReportList(page);
    }
}
